<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=8">
<meta name="Keywords" th:attr="content=${keywords}" />
<meta name="Description" th:attr="content=${description}" />
<!-- TemplateBeginEditable name="doctitle" -->
<title></title>
<!-- TemplateEndEditable --><!-- TemplateBeginEditable name="head" --><!-- TemplateEndEditable -->
<link rel="shortcut icon" href="favicon.ico" />
<link rel="icon" href="animated_favicon.gif" type="image/gif" />
<link th:href="${ecs_css_path}" rel="stylesheet" type="text/css" />

<!-- auto replace start-->
<script type="text/javascript" src="/static/js/common.js"></script>
<!-- auto replace end-->
<script type="text/javascript"  src="js/action.js"></script>
<script type="text/javascript" src="js/mzp-packed-me.js"></script>
<script type="text/javascript">
function $id(element) {
  return document.getElementById(element);
}
//切屏--是按钮，_v是内容平台，_h是内容库
function reg(str){
  var bt=$id(str+"_b").getElementsByTagName("h2");
  for(var i=0;i<bt.length;i++){
    bt[i].subj=str;
    bt[i].pai=i;
    bt[i].style.cursor="pointer";
    bt[i].onclick=function(){
      $id(this.subj+"_v").innerHTML=$id(this.subj+"_h").getElementsByTagName("blockquote")[this.pai].innerHTML;
      for(var j=0;j<$id(this.subj+"_b").getElementsByTagName("h2").length;j++){
        var _bt=$id(this.subj+"_b").getElementsByTagName("h2")[j];
        var ison=j==this.pai;
        _bt.className=(ison?"":"h2bg");
      }
    }
  }
  $id(str+"_h").className="none";
  $id(str+"_v").innerHTML=$id(str+"_h").getElementsByTagName("blockquote")[0].innerHTML;
}

</script>

</head>
<body>
<div th:replace="common/tpls/page_header_tpl::page_header"></div>

  <div th:replace="common/tpls/ur_here_tpl::ur_here"></div>

<div class="block clearfix">
  <!--left start-->
  <div class="AreaL">
    <!-- TemplateBeginEditable name="左边区域" -->
<div th:replace="common/tpls/category_tree_tpl::category_tree"></div>


  <div id="category_tree">
  <div class="tit">所有商品分类</div>
  <dl class="clearfix" style=" overflow:hidden;" >
   <div class="box1 cate" id="cate">
	<!--{foreach from=$categories item=cat name=no}-->
				<h1 onclick="tab()"  
		
		
		<!-- {if $smarty.foreach.no.first} -->
        style="border-top:none"
        <!-- {/if} --> 
		 
		
		
		>
		
		 		
		<span class="f_l"><img src="/static/images/btn_fold.gif" style="padding-top:10px;padding-right:6px;cursor:pointer;"></span>
		<a th:href="${cat.url}" class="  f_l"></a>

		</h1>
		<ul style="display:none" >
		<!--{foreach from=$cat.cat_id item=child}-->
		 <a class="over_2" th:href="${child.url}"></a>  
		 
<div class="clearfix">
<!--{foreach from=$child.cat_id item=childer}-->
<a class="over_3" th:href="${childer.url}"></a>
<!--{/foreach}-->
</div>   
		<!--{/foreach}-->
		</ul>
		<div style="clear:both"></div>
	<!--{/foreach}--> 
</div>
<div style="clear:both"></div>  
</div>  
 
<div class="blank"></div>
<script type="text/javascript">
obj_h4 = document.getElementById("cate").getElementsByTagName("h4")
obj_ul = document.getElementById("cate").getElementsByTagName("ul")
obj_img = document.getElementById("cate").getElementsByTagName("img")
function tab(id)
{ 
		if(obj_ul.item(id).style.display == "block")
		{
			obj_ul.item(id).style.display = "none"
			obj_img.item(id).src = "images/btn_fold.gif"
			return false;
		}
		else(obj_ul.item(id).style.display == "none")
		{
			obj_ul.item(id).style.display = "block"
			obj_img.item(id).src = "images/btn_unfold.gif"
		}
}
</script>
 <!-- #EndLibraryItem -->
<!-- TemplateEndEditable -->
<!-- TemplateBeginEditable name="左边广告区域（宽200px）" -->
<!-- TemplateEndEditable -->
    <!--AD end-->
    <div th:replace="common/tpls/history_tpl::history"></div>
  </div>
  <!--left end-->
  <!--right start-->
  <div class="AreaR">
   <!--商品详情start-->
   <div id="goodsInfo" class="clearfix">
    
     <!--商品图片和相册 start-->
     <div class="imgInfo">
     <a th:href="${pictures.0.img_url}" id="zoom1" class="MagicZoom MagicThumb" th:attr="title=${goods.goods_style_name}">
      <img th:src="${goods.goods_img}" th:attr="alt=${goods.goods_name}" width="360px;" height="360px"/>
     </a>
     <div class="blank5"></div>
    <div style="text-align:center; position:relative; width:100%;">
         {if $prev_good}
      <a th:href="${prev_good.url}"><img style="position: absolute; left:0;" alt="prev" src="./images/up.gif" /></a>
      {/if}
      <a href="javascript:;" onclick="window.open('gallery.php?id='); return false;"><img alt="zoom" src="./images/zoom.gif" /></a>
      {if $next_good}
      <a th:href="${next_good.url}"><img style="position: absolute;right:0;"  alt="next" src="./images/down.gif" /></a>
      {/if}
      </div>
      
 
         <div class="blank"></div>
           <!--相册 START-->
     <div th:replace="common/tpls/goods_gallery_tpl::goods_gallery"></div>
     <!--相册 END-->
         <!-- TemplateBeginEditable name="商品相册下广告（宽230px）" -->
<!-- TemplateEndEditable -->
     </div>
     <!--商品图片和相册 end-->
     <div class="textInfo">
     <form action="javascript:addToCart()" method="post" name="ECS_FORMBUY" id="ECS_FORMBUY" >
	  <h1 class="clearfix" >
      
      </h1> 
 
       <!-- {if $promotion} -->
      <div class="padd">
      <!-- {foreach from=$promotion item=item key=key} 优惠活动-->
      
      <!-- {if $item.type eq "snatch"} -->
      <a href="snatch.html" th:attr="title=${lang.snatch}" style="font-weight:100; color:#f69; text-decoration:none;">[]</a>
      <!-- {elseif $item.type eq "group_buy"} -->
      <a href="group_buy.html" th:attr="title=${lang.group_buy}" style="font-weight:100; color:#f69; text-decoration:none;">[]</a>
      <!-- {elseif $item.type eq "auction"} -->
      <a href="auction.html" th:attr="title=${lang.auction}" style="font-weight:100; color:#f69; text-decoration:none;">[]</a>
      <!-- {elseif $item.type eq "favourable"} -->
      <a href="activity.html" th:attr="title=${lang.favourable}" style="font-weight:100; color:#f69; text-decoration:none;">[]</a>
      <!-- {/if} -->
      <a th:href="${item.url}" title="{$lang.$item.type} " style="font-weight:100; color:#f69;"></a><br />
      <!-- {/foreach} -->
      </div>
      <!-- {/if} --> 
	   
	  
	  <ul class="ul2 clearfix">
        <li class="clearfix" style="width:100%">
       <dd>
 
       <!--本店售价-->
       <strong></strong><font class="shop" id="ECS_SHOPPRICE"></font> 
   
	   
	   <!-- {if $cfg.show_marketprice} 市场价格-->
       <font class="market"></font> 
       <!-- {/if} -->
       </dd>
       </li>
      
      
      
      
       <!-- {if $cfg.show_goodssn} 显示商品货号-->
      <li class="clearfix">
       <dd>
       <strong></strong>
      
       </dd>
       </li> 
        <!-- {/if} -->
       <!-- {if $goods.goods_number neq "" and $cfg.show_goodsnumber} 商品库存-->
       <li class="clearfix">
       <dd>
      
        <!-- {if $goods.goods_number eq 0} -->
          <strong></strong>
          <font color='red'></font>
        <!-- {else} -->
          <strong></strong>
           
        <!-- {/if} -->
     
       </dd>
       </li>  
       <!-- {/if} -->
       <!-- {if $goods.goods_brand neq "" and $cfg.show_brand} 显示商品品牌-->
      <li class="clearfix">
       <dd>
      
       <strong></strong><a th:href="${goods.goods_brand_url}" ></a>
    
       </dd>
       </li>  
        <!--{/if}-->
        <!-- {if $cfg.show_goodsweight} 商品重量-->
       <li class="clearfix">
       <dd>
       
       <strong></strong>
       
       </dd>
      </li>
      <!-- {/if} -->  
       <!-- {if $cfg.show_addtime} 上架时间-->
      <li class="clearfix">
       <dd>
    
      <strong></strong>
      
       </dd>
       </li>
       <!-- {/if} -->
       <li class="clearfix">
       <dd>
       <!--点击数-->
       <strong>：</strong>
       </dd>
      </li>
	  </ul>
	  
	  
	  <ul>
     
        

      <!--{if $volume_price_list } -->
      <li class="padd">
       <font class="f1">：</font><br />
			 <table width="100%" border="0" cellpadding="3" cellspacing="1" bgcolor="#aad6ff">
				<tr>
					<td align="center" bgcolor="#FFFFFF"><strong></strong></td>
					<td align="center" bgcolor="#FFFFFF"><strong></strong></td>
				</tr>
				<!-- {foreach from=$volume_price_list item=price_list key=price_key} -->
				<tr>
					<td align="center" bgcolor="#FFFFFF" class="shop"></td>
					<td align="center" bgcolor="#FFFFFF" class="shop"></td>
				</tr>
				<!-- {/foreach} -->
	     </table>
      </li>
      <!--{/if}-->

      <!--{if $goods.is_promote and $goods.gmt_end_time } 促销-->
      <!-- auto replace start-->
<script type="text/javascript" src="/static/js/lefttime.js"></script>
<!-- auto replace end-->
      <li class="padd loop" style="margin-bottom:5px; border-bottom:1px dashed #ccc;">
      <strong></strong><font class="shop"></font><br />
      <strong></strong>
      <font class="f4" id="leftTime"></font><br />
      </li>
      <!--{/if}-->
  
  
  <li class="clearfix">
       <dd >
  
       <!-- {foreach from=$rank_prices item=rank_price key=key} 会员等级对应的价格-->
       ：<font class="f1" id="ECS_RANKPRICE_" style=" padding-right:10px;"></font> 
       <!--{/foreach}-->
       
        <a href="javascript:collect()">收藏</a> |  
        <!-- {if $affiliate.on} -->
      <a href="user.html?act=affiliate&goodsid=" >推荐</a>
      <!-- {/if} -->
   </dd>
      </li>
  
       <!-- {if $goods.give_integral > 0} 购买此商品赠送积分-->
       <li class="clearfix">
       <dd >
       
        <strong></strong><font class="f4"> </font>
        
       </dd>
      </li>
      <!-- {/if} -->
      <!-- {if $goods.bonus_money} 红包-->
      <li class="padd loop" style="margin-bottom:5px; border-bottom:1px dashed #ccc;">
      <strong></strong><font class="shop"></font><br />
      </li>
      <!-- {/if} -->
  
      
       <!-- {if $cfg.use_integral} 购买此商品可使用积分-->

        <li class="clearfix">
       <dd>
       <strong></strong><font class="f4"> </font>
       </dd>
      </li>
       <!-- {/if} -->
         <!-- {if $goods.is_shipping} 为免运费商品则显示-->
      <li style="height:30px;padding-top:4px;">
      <br />
      </li>
      <!-- {/if} -->
            </ul>
         <ul class="bnt_ul">
     
      <!-- 
      <!-- {foreach from=$specification item=spec key=spec_key} -->
      <li class="padd loop">
      <strong>：</strong>
        <!-- 
                    <!-- {if $spec.attr_type eq 1} -->
                      <!-- {if $cfg.goodsattr_style eq 1} -->
                        <!-- {foreach from=$spec.values item=value key=key} -->
                        <label for="spec_value_">
                        <input type="radio" name="spec_" value="" id="spec_value_" {if $key eq 0}checked{/if} onclick="changePrice()" />
                         [{if $value.price gt 0}{elseif $value.price lt 0}{/if} ] </label>
                        <!-- {/foreach} -->
                        <input type="hidden" name="spec_list" value="" />
                        <!-- {else} -->
                        <select name="spec_" onchange="changePrice()" >
                          <!-- {foreach from=$spec.values item=value key=key} -->
                          <option label="" value=""> {if $value.price gt 0}{elseif $value.price lt 0}{/if}{if $value.price neq 0}{/if}</option>
                          <!-- {/foreach} -->
                        </select>
                        <input type="hidden" name="spec_list" value="" />
                      <!-- {/if} -->
                    <!-- {else} -->
                      <!-- {foreach from=$spec.values item=value key=key} -->
                      <label for="spec_value_">
                      <input type="checkbox" name="spec_" value="" id="spec_value_" onclick="changePrice()" />
                       [{if $value.price gt 0}{elseif $value.price lt 0}{/if} ] </label>
                      <!-- {/foreach} -->
                      <input type="hidden" name="spec_list" value="" />
                    <!-- {/if} -->
      </li>
      <!-- {/foreach} -->
      <!-- 
      
           <li class="clearfix">
       <dd>
       <strong>：</strong>
        <input name="number" type="text" id="number" value="1" size="4" onblur="changePrice()" style="border:1px solid #ccc; "/> <strong>：</strong><font id="ECS_GOODS_AMOUNT" class="f1"></font>
       </dd>
       </li>
      
      <li class="padd">
      <a  class="btn_pink_138x32" href="javascript:addToCart()" style="color:#FFF;text-decoration:none;">加入购物车</a>
     
      </li>
     
      </ul>
      </form>
     </div>
   </div>
   <div class="blank"></div>
   <!--商品详情end-->
   <!--商品描述，商品属性 START-->
     <div class="box">
 
      <div style="padding:0 0px;">
        <div id="com_b" class="history clearfix">
        <h2>商品描述</h2>
        <h2 class="h2bg"></h2>
         <h2 class="h2bg">商品标签</h2>
           <h2 class="h2bg">相关商品</h2>
        <!-- {if $package_goods_list} -->
        <h2 class="h2bg" style="color:red;"></h2>
        <!-- {/if} -->
        </div>
      </div>    <div class="box_1">
      <div id="com_v" class="  " style="padding:6px;"></div>
      <div id="com_h">
       <blockquote>
        
       </blockquote> 
       
       <blockquote>
      <table class="table" width="100%" border="0" cellpadding="3" cellspacing="1" bgcolor="#dddddd">
        <!-- {foreach from=$properties item=property_group key=key} -->
        <tr>
          <th colspan="2" bgcolor="#FFFFFF"></th>
        </tr>
        <!-- {foreach from=$property_group item=property} -->
        <tr>
          <td bgcolor="#FFFFFF" align="left" width="30%" class="f1">[]</td>
          <td bgcolor="#FFFFFF" align="left" width="70%"></td>
        </tr>
        <!-- {/foreach}-->
        <!-- {/foreach}-->
      </table>
     </blockquote>

     <blockquote>
   
<div th:replace="common/tpls/goods_tags_tpl::goods_tags"></div>


     <div class="box">
     <div class="box_1">
      <h3><span class="text"></span></h3>
      <div class="boxCenterList clearfix ie6">
       <form name="tagForm" action="javascript:;" onSubmit="return submitTag(this)" id="tagForm">
        <p id="ECS_TAGS" style="margin-bottom:5px;">
          <!-- 标记{foreach from=$tags item=tag}-->
          <a href="search.html?keywords=" style="color:#006ace; text-decoration:none; margin-right:5px;">[]</a>
          <!-- 结束标记{/foreach} -->
        </p>
        <p>
          <input type="text" name="tag" id="tag" class="inputBg" size="35" />
          <input type="submit" value="添 加" class="bnt_blue" style="border:none;" />
          <input type="hidden" name="goods_id" value=""  />
        </p>
                <script type="text/javascript">
                //<![CDATA[
                {literal}
                /**
                 * 用户添加标记的处理函数
                 */
                function submitTag(frm)
                {
                  try
                  {
                    var tag = frm.elements['tag'].value;
                    var idx = frm.elements['goods_id'].value;

                    if (tag.length > 0 && parseInt(idx) > 0)
                    {
                      Ajax.call('user.php?act=add_tag', "id=" + idx + "&tag=" + tag, submitTagResponse, "POST", "JSON");
                    }
                  }
                  catch (e) { alert(e); }

                  return false;
                }

                function submitTagResponse(result)
                {
                  var div = document.getElementById('ECS_TAGS');

                  if (result.error > 0)
                  {
                    alert(result.message);
                  }
                  else
                  {
                    try
                    {
                      div.innerHTML = '';
                      var tags = result.content;

                      for (i = 0; i < tags.length; i++)
                      {
                        div.innerHTML += '<a href="search.html?keywords='+tags[i].word+'" style="color:#006ace; text-decoration:none; margin-right:5px;">' +tags[i].word + '[' + tags[i].count + ']<\/a>&nbsp;&nbsp; ';
                      }
                    }
                    catch (e) { alert(e); }
                  }
                }
                {/literal}
                //]]>
                </script>
              </form>
      </div>
     </div>
    </div>
    <div class="blank5"></div>

 <!-- #EndLibraryItem -->
     </blockquote>
     
     
    

     <!-- {if $package_goods_list} -->
     <blockquote>
       <!-- {foreach from=$package_goods_list item=package_goods} -->
			  <strong></strong><br />
        <table width="100%" border="0" cellpadding="3" cellspacing="1" bgcolor="#dddddd">
				<tr>
					<td bgcolor="#FFFFFF">
					<!-- {foreach from=$package_goods.goods_list item=goods_list} -->
					<a href="goods.html?id=" target="_blank"><font class="f1"></font></a> &nbsp;&nbsp;X <br />
					<!-- {/foreach} -->
					</td>
					<td bgcolor="#FFFFFF">
					<strong></strong><font class="market"></font><br />
          <strong></strong><font class="shop"></font><br />
          <strong></strong><font class="shop"></font><br />
					</td>
					<td bgcolor="#FFFFFF">
					<a href="javascript:addPackageToCart()" style="background:transparent"><img src="/static/images/bnt_buy_1.gif" th:attr="alt=${lang.add_to_cart}" /></a>
					</td>
				</tr>
	    </table>
       <!-- {/foreach} -->
     </blockquote>
     <!-- {/if} -->
     
     
     <blockquote>
   
<div th:replace="common/tpls/goods_related_tpl::goods_related"></div>


     <div class="box">
     <div class="box_1">
      <h3><span class="text"></span></h3>
      <div class="boxCenterList clearfix ie6">
       <form name="tagForm" action="javascript:;" onSubmit="return submitTag(this)" id="tagForm">
        <p id="ECS_TAGS" style="margin-bottom:5px;">
          <!-- 标记{foreach from=$tags item=tag}-->
          <a href="search.html?keywords=" style="color:#006ace; text-decoration:none; margin-right:5px;">[]</a>
          <!-- 结束标记{/foreach} -->
        </p>
        <p>
          <input type="text" name="tag" id="tag" class="inputBg" size="35" />
          <input type="submit" value="添 加" class="bnt_blue" style="border:none;" />
          <input type="hidden" name="goods_id" value=""  />
        </p>
                <script type="text/javascript">
                //<![CDATA[
                {literal}
                /**
                 * 用户添加标记的处理函数
                 */
                function submitTag(frm)
                {
                  try
                  {
                    var tag = frm.elements['tag'].value;
                    var idx = frm.elements['goods_id'].value;

                    if (tag.length > 0 && parseInt(idx) > 0)
                    {
                      Ajax.call('user.php?act=add_tag', "id=" + idx + "&tag=" + tag, submitTagResponse, "POST", "JSON");
                    }
                  }
                  catch (e) { alert(e); }

                  return false;
                }

                function submitTagResponse(result)
                {
                  var div = document.getElementById('ECS_TAGS');

                  if (result.error > 0)
                  {
                    alert(result.message);
                  }
                  else
                  {
                    try
                    {
                      div.innerHTML = '';
                      var tags = result.content;

                      for (i = 0; i < tags.length; i++)
                      {
                        div.innerHTML += '<a href="search.html?keywords='+tags[i].word+'" style="color:#006ace; text-decoration:none; margin-right:5px;">' +tags[i].word + '[' + tags[i].count + ']<\/a>&nbsp;&nbsp; ';
                      }
                    }
                    catch (e) { alert(e); }
                  }
                }
                {/literal}
                //]]>
                </script>
              </form>
      </div>
     </div>
    </div>
    <div class="blank5"></div>

 <!-- #EndLibraryItem -->
     </blockquote>
     

      </div>
     </div>
    </div>
    <script type="text/javascript">
    <!--
    reg("com");
    //-->
    </script>
  <div class="blank"></div>
  <!--商品描述，商品属性 END-->
  <!-- TemplateBeginEditable name="右边可编辑区域" -->
<div th:replace="common/tpls/bought_note_guide_tpl::bought_note_guide"></div>

<!-- auto replace start-->
<script type="text/javascript" src="/static/js/transport_jquery.js"></script>
<script type="text/javascript" src="/static/js/utils.js"></script>
<!-- auto replace end-->
<div id="ECS_BOUGHT">
 <!-- #EndLibraryItem -->
<div th:replace="common/tpls/bought_goods_tpl::bought_goods"></div>

<!-- {if $bought_goods} -->
     <div class="box">
     <div class="box_1">
      <h3><span class="text"></span></h3>
      <div class="boxCenterList clearfix ie6" style="padding:2px;">
       <!--{foreach from=$bought_goods item=bought_goods_data}-->
        <div class="goodsItem" style="padding: 10px 2px 15px 2px;">
         <a th:href="${bought_goods_data.url}"><img th:src="${bought_goods_data.goods_thumb}" th:attr="alt=${bought_goods_data.goods_name}"  class="goodsimg" /></a><br />
         <p><a th:href="${bought_goods_data.url}" th:attr="title=${bought_goods_data.goods_name}"></a></p> 
         <!-- {if $bought_goods_data.promote_price neq 0} -->
        <font class="shop_s"></font>
        <!-- {else} -->
        <font class="shop_s"></font>
        <!-- {/if} -->
        </div>
        <!-- {/foreach} -->
      </div>
     </div>
    </div>
    <div class="blank5"></div>
    <!-- {/if} -->
 <!-- #EndLibraryItem -->
<div th:replace="common/tpls/comments_tpl::comments"></div>

<!-- auto replace start-->
<script type="text/javascript" src="/static/js/transport_jquery.js"></script>
<script type="text/javascript" src="/static/js/utils.js"></script>
<!-- auto replace end-->
<div id="ECS_COMMENT"> 

 <!-- #EndLibraryItem -->
<!-- TemplateEndEditable -->
  </div>
  <!--right end-->
</div>
<div th:replace="common/tpls/page_footer_tpl::page_footer"></div>
</body>
<script type="text/javascript">
var goods_id = ;
var goodsattr_style = ;
var gmt_end_time = ;
{foreach from=$lang.goods_js item=item key=key}
var  = "";
{/foreach}
var goodsId = ;
var now_time = ;

<!-- {literal} -->
onload = function(){
  changePrice();
  fixpng();
  try { onload_leftTime(); }
  catch (e) {}
}

/**
 * 点选可选属性或改变数量时修改商品价格的函数
 */
function changePrice()
{
  var attr = getSelectedAttributes(document.forms['ECS_FORMBUY']);
  var qty = document.forms['ECS_FORMBUY'].elements['number'].value;

  Ajax.call('goods.php', 'act=price&id=' + goodsId + '&attr=' + attr + '&number=' + qty, changePriceResponse, 'GET', 'JSON');
}

/**
 * 接收返回的信息
 */
function changePriceResponse(res)
{
  if (res.err_msg.length > 0)
  {
    alert(res.err_msg);
  }
  else
  {
    document.forms['ECS_FORMBUY'].elements['number'].value = res.qty;

    if (document.getElementById('ECS_GOODS_AMOUNT'))
      document.getElementById('ECS_GOODS_AMOUNT').innerHTML = res.result;
  }
}
<!-- {/literal} -->
</script>
</html>
